<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Register</title>
    <link rel="stylesheet" href="/static/bootstrap.css">
    <style>
        div.register {
            align-content: center;
            width: 400px;
            margin: 0 auto;
        }
    </style>
</head>
<body>

<div class="register">
    <h1>注册</h1>
    <form>
        {% for field in register_form %}
            {% if field.name == 'code' %}
                <div class="form-group">
                    <label for="exampleInputEmail1">{{ field.label }}</label>
                    <div class="clearfix">
                        <div class="col-md-6" style="padding-left: 0">
                            {{ field }}
                        </div>
                        <div class="col-md-6">
                            <button type="submit" class="btn btn-default">获取验证码</button>
                        </div>
                    </div>
                </div>
            {% else %}
                <div class="form-group">
                    <label for="{{ field.id_for_label }}">{{ field.label }}</label>
                    {{ field }}
                </div>
            {% endif %}
        {% endfor %}
        <button type="submit" class="btn btn-primary">注册</button>
    </form>
</div>


</body>
</html>